<extend name="./Application/Admin/View/base.html" />
<block name="title"><title><?php echo C(APP_NAME);?>PC端管理</title></block>
<block name="stylesheets">
<link href="__PUBLIC__/assets/css/select2.css" rel="stylesheet">

</block>
<block name="stylecss">
<style type='text/css'>
    table tr td{
        width: 80%;
    }
    table tr th{
        width: 16%;
        text-align: center;
        vertical-align: middle!important;
    }
</style>
</block>
<block name="smallmenu">
<ul class="breadcrumb">
	<li>
		<i class="ace-icon fa fa-home home-icon"></i>
		<a href="{:U('Index/index')}">主页</a>
	</li>
    <li>
		<a href="{:U('Goods/index_jc')}">教程列表</a>
	</li>
	<li class="active">修改教程信息</li>
</ul><!-- /.breadcrumb -->

<!-- #section:basics/content.searchbox -->
<div class="nav-search" id="nav-search"></div><!-- /.nav-search -->
</block>
<block name="content">
<form action="__CONTROLLER__/jc_edit" method='post' id='myformedit' class="myformedit" enctype="multipart/form-data">
<input type="hidden" name='goods_id' value="{$goods_arr.goods_id}">
<input type="hidden" name='action' value="jc_edit_action">
<div class="row" style="margin-bottom:7px">
    <div class="col-xs-12"><span class="label label-success"><i class="ace-icon fa fa-user bigger-120"></i> 教程信息</span></div>
</div>
<table class="table table-striped table-bordered table-hover" >
    <tr>
        <th>教程编号</th>
        <td><input type="text" name='goods_num' value="{$goods_arr.goods_num}" class="col-xs-6 ninputxt">
        <span class="Validform_checktip">必填项</span>
        </td>
    </tr>
    <tr>
        <th>教程名称</th>
        <td><input type="text" name='goods_name' value="{$goods_arr.goods_name}" class="col-xs-6 ninputxt">
        <span class="Validform_checktip">必填项</span>
        </td>
    </tr>
    <tr>
        <th>教程封面图</th>
        <td>
            <div class="nfile_imgbox" >
                <input type="file" class="nfile" id="file_upload" name="goods_pic" />
                <?php if (!empty($goods_arr['goods_pic'])) { ?>
                <img src="{$goods_arr.goods_pic}" id="preview">
                <?php }else{ ?>
                <img src="__PUBLIC__/assets/images/addfile.png" id="preview">
                <?php } ?>
                <a class="nimg_style">+<img src=""> </a>
            </div>
        </td>
    </tr>
    <tr>
        <th>专业</th>
        <td><select name="goods_major_id" id="" class="col-xs-6">
            <option value="1" <?php if ($goods_arr['goods_major_id'] == 1): ?>selected<?php endif ?>>电吉他</option>
            <option value="2" <?php if ($goods_arr['goods_major_id'] == 2): ?>selected<?php endif ?>>爵士鼓</option>
            <option value="3" <?php if ($goods_arr['goods_major_id'] == 3): ?>selected<?php endif ?>>电贝司</option>
            <option value="4" <?php if ($goods_arr['goods_major_id'] == 4): ?>selected<?php endif ?>>音乐理论</option>
        </select>
        <span class="Validform_checktip">必选项</span>
        </td>
    </tr>
    <tr>
        <th>等级</th>
        <td><select name="goods_level" id="" class="col-xs-6">
            <option value="1" <?php if ($goods_arr['goods_level'] == 1): ?>selected<?php endif ?>>1级</option>
            <option value="2" <?php if ($goods_arr['goods_level'] == 2): ?>selected<?php endif ?>>2级</option>
            <option value="3" <?php if ($goods_arr['goods_level'] == 3): ?>selected<?php endif ?>>3级</option>
            <option value="4" <?php if ($goods_arr['goods_level'] == 4): ?>selected<?php endif ?>>4级</option>
            <option value="5" <?php if ($goods_arr['goods_level'] == 5): ?>selected<?php endif ?>>5级</option>
            <option value="6" <?php if ($goods_arr['goods_level'] == 6): ?>selected<?php endif ?>>6级</option>
            <option value="7" <?php if ($goods_arr['goods_level'] == 7): ?>selected<?php endif ?>>7级</option>
            <option value="8" <?php if ($goods_arr['goods_level'] == 8): ?>selected<?php endif ?>>8级</option>
            <option value="9" <?php if ($goods_arr['goods_level'] == 9): ?>selected<?php endif ?>>9级</option>
        </select>
        <span class="Validform_checktip">必选项</span>
        </td>
    </tr>
    <tr>
        <th>教程价格</th>
        <td><input type="text" name='goods_price' value="{$goods_arr.goods_price}" class="col-xs-6 ninputxt">
        <span class="Validform_checktip">必填项</span>
        </td>
    </tr>
    <tr>
        <th>教程简介</th>
        <td><textarea name='goods_introduction' cols='60' rows='8' class="col-xs-6 ninputxt">{$goods_arr.goods_introduction}</textarea>
        	<span class="Validform_checktip">必填项</span>
        	
        </td>
    </tr>
    <tr>
        <td colspan="2"><button type="submit" class="btn btn-sm btn-primary" >提交</button> <span class="btn btn-sm" onClick="location.href='{:U('Goods/index_jc')}'">返回</span></td>
    </tr>
</table>
</form>
</block>
<block name="scripts">
<script src="__PUBLIC__/assets/js/select2.js"></script>
</block>
<block name="jscript">
<script script="text/javascript">
    $(function(){
        $('#menu_data').addClass('active open');
        $('#menu_jc_list').addClass('active');
    });
</script>

</block>